<template>
  <el-container class="basic-layout">
    <!-- 顶部导航栏 -->
    <el-header class="layout-header">
      <GlobalHeader />
    </el-header>

    <!-- 中间内容区域 -->
    <el-main class="layout-main">
      <router-view />
    </el-main>

    <!-- 底部版权信息 -->
    <el-footer class="layout-footer">
      <GlobalFooter />
    </el-footer>
  </el-container>
</template>

<script setup lang="ts">
import GlobalHeader from '../components/GlobalHeader.vue'
import GlobalFooter from '../components/GlobalFooter.vue'
</script>

<style scoped>
.basic-layout {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.layout-header {
  padding: 0;
  height: auto;
  background-color: #fff;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  z-index: 1000;
}

.layout-main {
  flex: 1;
  padding: 20px;
  background-color: #f5f5f5;
  overflow-y: auto;
}

.layout-footer {
  padding: 0;
  height: auto;
  background-color: #fff;
  border-top: 1px solid #e8e8e8;
}

/* 响应式设计 */
@media (max-width: 768px) {
  .layout-main {
    padding: 16px;
  }
}

@media (max-width: 480px) {
  .layout-main {
    padding: 12px;
  }
}
</style>
